Field of the Invention
The present invention relates to image processing of rendering a scene by tracing rays.
Description of the Related Art
In recent years, there is proposed a technique, called computational photography, of generating image data based on information (to be referred to as “light-field data” hereinafter) about the directions and intensities of rays in a space (see, for example, literature 1). Since image data for which the focus is adjusted after image capturing can be generated using this technique, it is possible to advantageously compensate for a failure in focus adjustment at the time of image capturing with image processing.
In computational photography, image data (light-field data) for which focus adjustment is possible after shooting is obtained using a light field camera. Examples of the light field camera are a Plenoptic camera in which a microlens array is arranged in front of an image sensor and a multiple-lens camera in which a number of sets of image sensors and lenses are incorporated.
The user may want to synthesize an image (to be referred to as a “CG image” hereinafter) created using a computer graphic rendering method (to be referred to as a “CG rendering method” hereinafter) on the image for which focus adjustment is possible. To do this, if CG rendering is performed without using light-field data, it is necessary to prepare CG images which are focused on all distances. In this case, however, since it takes long time to create such CG images, it is not preferable to prepare the CG images which are focused on all distances.
Therefore, it is desirable to create a CG image by computational photography by generating light-field data similar to that captured by the light field camera using the CG rendering method, and using the generated light-field data.
As a method of creating light-field data by the CG rendering method, there is provided a method described in literature 2. Since, however, this method generates light-field data based on one ray for each pixel of an image, the quality of the generated light-field data is insufficient to be synthesized with captured light-field data.    Literature 1: R. Ng, M. Levoy, M. Bredif, G. Duval, M. Horowitz, P. Hanrahan “Light Field Photography with a Hand-held Plenoptic Camera” Stanford Tech Report CTSR 2005-02, 2005    Literature 2: Steven G. Parker et al. “OptiX™: A General Purpose Ray Tracing Engine” ACM Transactions on Graphics, August 2010